/**
 * Created by P0015475 on 2015/9/11.
 */
var myApp = angular.module('myApp', ['ngRoute']);
myApp.config(function ($routeProvider, $httpProvider) {

    $routeProvider.when('/welcome', {
        templateUrl: 'welcome',
        controller: 'centerController'
    });
    $routeProvider.otherwise({redirectTo: '/welcome'});


});
myApp.controller('centerController', function ($rootScope, $location) {
    $rootScope.userListPage = function () {
        $location.path('/user/view');
    };
    $rootScope.roleListPage = function () {
        $location.path('/role/view');
    };
    $rootScope.welcomePage = function () {
        $location.path('/welcome');
    };
});

